-
-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update UserMenu.cshtml #100
Conversation
@@ -32,6 +29,9 @@ | |||
<li><a class="dropdown-item" asp-area="OrchardCore.Users" asp-action="Display" asp-controller="Admin" asp-route-id="@userId" asp-route-returnUrl="@FullRequestPath"><span><i class="far fa-address-card" aria-hidden="true"></i></span> <span> @T["Profile"]</span></a></li> | |||
} | |||
<li><a class="dropdown-item" asp-area="OrchardCore.Users" asp-controller="Account" asp-action="ChangePassword" asp-route-returnUrl="@FullRequestPath"><span><i class="fas fa-key" aria-hidden="true"></i></span> <span> @T["Change password"]</span></a></li> | |||
|
|||
@await RenderSectionAsync("UserMenuItems", required: false) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's something new we added to allow others to inject items in this menu. We should at some point submit a PR to remove most of these menu items from the view and use filters to inject them into the view
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Happy to hear that, I will have a look and merge your PR ASAP
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@MikeAlhayek I presume this should be in the Users module, right? after that we can inject the menu items from other modules
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should only be in UserMenu view which will optionally allow others to inject into this zone
TODO: Use CommonPermissions.EditOwnUser once 1.6.0 is released | ||
*@ | ||
@if (await AuthorizationService.AuthorizeAsync(User, CommonPermissions.ManageUsers)) | ||
@if (await AuthorizationService.AuthorizeAsync(User, CommonPermissions.EditOwnUser)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The build failed, we need to upgrade to 1.6.0
, I will update in another PR then I will merge this
@MikeAlhayek could you please rebase on the |
Could you please rebase, so I can merge this? |
done |
Please do it one more time, there was a build issue, that has been fixed and merged |
done |
Thanks a lot |
No description provided.